
CONTACT CENTER 7.0 AGENT WEBSERVICES SOFTWARE DEVELOPMENT KIT README

The Contact Center Multimedia (CCMM) Agent Webservices are installed by default 
when CCMM is installed on a server as part of AACC 7.0 or AACS 7.0 installation.

These Webservices offer a range of SOAP functionality from the default location - either 

  * http://ccmm_server_name/ccmmagentwebservices running on port 80

    or

  * https://ccmm_server_name/ccmmagentwebservices running on port 443

depending on the active Contact Center security configuration.

Note: The Web.config file in the root folder contains a MaximumConnections setting.
This is used to manage HTTP traffic, i.e., an error will occur if this limit is 
exceeded. Site admins can increase this as required but naturally there will 
be performance impacts.

The CCMM Agent Webservices Software Development Kit (SDK) consists of the following elements:

1. The CCMM Agent Webservices helpfile
2. Sample Agent Webservices client that demonstrates 
   - Logging an agent user into CCMM
   - Reading and replying to email contacts
   - Originating new email contacts


+--------------------------------------------------------------------------+
| 1. The CCMM Agent Webservices helpfile (CCMM Agent Webservices Help.chm) |
+--------------------------------------------------------------------------+

The API documentation is provided in .chm format. This is accompanied by an 
introduction and brief tutorial illustrating how to start creating a .Net-based 
client to consume the Agent Webservices using Visual Studio .Net.


+------------------------------------+
| 2. Sample Agent Webservices client |
+------------------------------------+

This utility allows users to log into CCMM, read and reply to email contacts, and 
to Originate new email contacts. It illustrates the basic pattern of validating 
with, and connecting to, Agent Webservices.

The solution can be opened via the .sln file AgentWebservicesClient.sln in the
AgentWebservicesClient folder. It was created in Visual Studio 2010. It has been
validated to work with Visual Studio 2013 (opening the solution in Visual Studio
2013 will prompt for "one-way upgrade" and this has been validated to work
successfully).

Before execution, the "Service References" shown in the Solution Explorer should
be updated to point to the appropriate web services on your deployed CCMM installation. 

To do this,

 - Select each of the Service References in turn 
 - Rightclick on the service reference and select the Configure service reference option 
 - Input your CCMM server hostname or IP address, being careful to specify the correct
   protocol (http, or https) for the active security mode on the AACC 7.0 server.

If you are still having difficulty or you have moved back to Visual Studio 2008
and are having problems with the "Service References" you may delete the 
service reference and recreate it, pointing to your own server, but using the 
current naming conventions, i.e., 

 - http(s)://CCMM_IP_ADDRESS/ccmmagentwebservices/AgentEmailWS.asmx 

The CCT server IP also needs to be updated manually in the Settings.settings (in 
the solution's Properties folder). The app.config file (in the base folder)
should update automatically but check it if there are issues with connectivity.

If you are working with an AACC server that is running in Secure mode (HTTPS
only, which is the default for Contact Center 7.0), and the target CCMM server 
is operating on the install-provided security certificate you will need to 
disable certificate validation in the app.config settings file of the sample
client,

  <configuration>
    <system.net>
      <settings>
        <servicePointManager checkCertificateName="false"/>
      </settings>  
    </system.net>
  </configuration>
     
(Also note that Visual Studio may prompt you with a security warning due to the use of this certificate.)

The client is now ready to build and execute against your Contact Center 7.0
CCMM installation.


Note:
-----
As of Contact Center 7.0 email message body may be in HTML format (prior to 7.0
only plain text was supported). The use of HTML versions of the web service
methods is not demonstrated in the sample client as there is no difference in 
usage. Use the Html versions of the methods if your client application generates
and processes Html type mail body text.

There is a Html equivalent for each webservice method, e.g.,

private long SendMail(...)      // Send mail with text body
private long SendMailHtml(...)  // Send mail with Html body

public long Reply(...)          // Reply with text body
public long ReplyHtml(...)      // Reply with Html body

public long Forward(...)        // Forward with text body
public long ForwardHtml(...)    // Forward with Html body

* The pre-existing methods and interfaces have not changed in 7.0
  -- Only additional equivalents have been added to support Html message body content.
* In all cases the Text and Html versions of these methods take the same argument list
  -- In the case of Html method versions it is expected that the supplied message body (string) contains Html content.

Note:
-----
Contact Center 7.0 uses Microsoft .Net version 4.5.2. The sample application has
been tested with .Net 4.5.2 and Visual Studio 2013. You may update the project assembly 
in Visual Studio to use .Net 4.5.2.


USING THE SAMPLE CLIENT:
------------------------
Login to CCMM using normal agent ID/password, e.g., 3000 / 3000 using the controls 
in the top-right corner of the sample client user interface (UI). This calls a 
login web service which returns a session key; the session key is used for validation 
throughout all subsequent web service calls.

NOTE: Some CCT functionality is also incorporated into this sample client and a 
CCT login is included, but the CCT Reference Client is the definitive resource for 
CCT integration.

Once connected, the Client checks for Closed Reason Codes and will issue a warning 
if none are retrieved. (as these codes are needed to close contacts). Closed reason codes
are configured through CCMM administration.

 With successful agent login and Closed Reason Code retrieval the sample client can be used to,

(a) Read a Contact 
   or 
(b) Originate a New Mail


(a) Reading a Contact:

Enter the Contact ID and Click "Read Contact" button.

Contact data is displayed above a Tree Control showing any included Actions.
For email contacts whose Status is not Closed, the "Reply", "Reply All" 
and "Forward" buttons are enabled. The "Close Contact" function is also made 
available at this point.

To Reset and return to Read Contact mode, click Cancel.


(b) Originate a New Mail:

A Skillset must be selected from the drop down control in the bottom right
corner of the sample client UI in order to send a new mail. This skillset must also 
be associated with a mailbox. Skillset and mailbox configuration are part of CCMM Administration.

Other mandatory fields are not enforced on the client but at a minimum, the "To" address 
must be provided.

Click "Send" to send the mail.

Once processed, CCMM will create a Contact entry in its database. The Client displays 
this contact. The ID of the contact is shown in the "Read Contact" box, with its 
Actions and other data displayed at the top of the UI.

Note that attachment files are not uploaded to the server by the sample client, 
it is the responsibility of the developer to create the correct attachment files
in the correct server locations.

Applications such as Contact Center Agent Desktop (CCAD) upload outgoing
attachments to subfolders on the CCMM server at a location specified by the OutAttachShare 
site parameter. This folder is created automatically on the server when CCMM is installed.
